package com.erlinyou.im.dao.repository.groupmove;

import java.util.List;
import java.util.Map;

import org.springframework.data.jpa.repository.Query;

import com.erlinyou.base.dao.BaseRepository;
import com.erlinyou.im.model.groupmove.Ofcontacts;
import com.erlinyou.im.model.groupmove.OfcontactsId;

public interface OfcontactsRepository extends BaseRepository<Ofcontacts, OfcontactsId>{

	@Query(value="SELECT cid,crid,cuptime from ofcontacts where ctype = 'media' and substring_index(crid,'@',1) != 0 and substring_index(cid,'@',1) != 0;",nativeQuery=true)
	List<Map<String, Object>> selectByChat();

	
}
